
package com.hlkj.pay.service.order;
/*
 * Hlpay-Plus aggregate payment system.
 * Copyright (c) 2024-2025 Hlpay Team Copyright has the right of final interpretation.
 */

import java.util.List;

import com.hlkj.framework.common.pojo.PageResult;
import com.hlkj.pay.dto.order.OrderSubsidyDto;
import com.hlkj.pay.dto.order.PayOrderSubsidyDto;
import com.hlkj.pay.dto.order.PayOrderSubsidyQueryDto;
import com.hlkj.pay.dto.order.RefundOrderSubsidyDto;
import com.hlkj.pay.enums.PayOrderEnums;
import com.hlkj.pay.infrastructure.model.order.OrderFundDetailDO;
import com.hlkj.pay.infrastructure.model.order.OrderSubsidyDO;
import com.hlkj.pay.infrastructure.model.order.OrderSubsidyDetailDO;
import com.hlkj.pay.infrastructure.model.order.PayOrderDO;
import com.hlkj.pay.vo.order.req.SubsidyOrderParamReq;
import com.hlkj.pay.vo.order.req.SubsidyRefundOrderParamReq;

/**
 * @author HlpayTeam
 * @date 2024/10/10 15:18
 */
public interface IPayOrdeSubsidyService {

    OrderSubsidyDto addSubsidyInfo(SubsidyOrderParamReq subsidyOrderParamReq, List<PayOrderSubsidyDto> payOrderSubsidyDtos, PayOrderDO payOrderDO);

    List<OrderSubsidyDetailDO> queryPaySubsidyInfo(String payOrderNo);

    OrderSubsidyDO queryOrderSubsidyInfo(String batchNo, String mchOrderNo);

    OrderSubsidyDO queryRefundSubsidyInfo(String batchNo, String mchRefundOrderNo);

    OrderSubsidyDto addSubsidyRefundInfo(SubsidyRefundOrderParamReq subsidyOrderParamReq, List<RefundOrderSubsidyDto> refundOrderSubsidyList, PayOrderDO payOrderDO,String requestId);

    void updateAcctInfoCallBack(PayOrderDO orderDb, List<OrderFundDetailDO> orderFunds);

    OrderSubsidyDto updateSubsidy(List<OrderSubsidyDetailDO> orderSubsidyDetailDOList, String batchNo);

    OrderSubsidyDto  querySubsidyDto(String batchNo);

    OrderSubsidyDto  querySubsidyDtoByPayOrderNo(String payOrderNo);

    List<OrderSubsidyDetailDO> querySubsidyDetailInfo(String batchNo);

    List<OrderSubsidyDO> querySubsidyList(PayOrderSubsidyQueryDto payOrderSubsidyQueryDto);

    void updateSubsidyStatus(Long id, PayOrderEnums.PAY_ORDER_SUBSIDY_STATUS payOrderSubsidyStatus);

    void updateSubsidyDetails(List<OrderSubsidyDetailDO> orderSubsidyDetailDOList);

    PageResult<OrderSubsidyDO> queryPage(PayOrderSubsidyQueryDto orderSubsidyQueryDto);
}
